home *** CD-ROM | disk | FTP | other *** search
/ Cream of the Crop 12 / Cream of the Crop 12 (Part II) / Cream of the Crop 12 (Part II).iso / OS2 / FCHEK284.ZIP / test / comusage.f < prev    next >
Encoding:
Text File  |  1994-11-06  |  590 b   |  37 lines

  1.       Program Main
  2.           common a,b,c
  3.           print *,a,b,c
  4.       Call Input
  5.       Call Comp
  6.       Call Output
  7.       End
  8.  
  9.       Subroutine Input
  10.       Common /INP/ x1,x2,x3,x4
  11.       Real x1,x2,x3
  12.       Common/LAST/ y1,y2,y3
  13.       Write(*,*) 'Enter 3 Values'
  14.       Read (*,*) x1,x2,x3
  15.       y2 = y3
  16.       Return
  17.       End
  18.  
  19.       Subroutine Comp
  20.       Common /INP/ A,B,C
  21.           Common /ZAP/ t1,t2,t3
  22.       Real A,B,C
  23.       Common /OUTP/ AVG
  24.       Real AVG
  25.       Avg = (A+B+C)/3
  26.       Return
  27.       End
  28.  
  29.       Subroutine Output
  30.       Common /OUTP/ Averag
  31.       Real Averag
  32.       Common /LAST/ n1,n2,n3
  33.       Write (*,*) 'Average =',Averag
  34.       n1 = 8
  35.       Return
  36.       End
  37.